<?php if (!defined('THINK_PATH')) exit();?><table id="zds_dg"></table>
<style>
    .uploadpic{
        float:left;
        width: 295px;
        text-align:center;
        height:165px;
    }
    .uploadpic h3{
        text-align:left;
        border:1px solid  #95B8E7;
        float:left;
        padding:4px;
        background-color:#95B8E7;
        color:#FFF;
    }
    .up-content{
        border:1px solid  #95B8E7;
        padding:4px;
    }
    .w10{
        float:left;
        width:10px;
        color:#FFF;
    }
    .items{
        padding:10px 0 4px 0;
        border-top: solid 1px #D6D4D4;
        display: block;
    }
    #dd div{
        padding-right: 10px;
        padding-bottom: 10px;
    }
    .addItems{
        float: left;
    }


    .add_table{
        width:100%;
    }
    .add_table th{
        width:140px;
        background-color: #E0ECFF;
        padding: 8px 0 8px 0;
        border-right:solid 1px #95B8E7;
        border-bottom: solid 1px #95B8E7;
    }
    .add_table td{
        border-bottom: solid 1px #95B8E7;
    }
    .add_table tr{
        border:solid 1px #95B8E7;
    }
    .tb_head{
        text-align: center;
        padding: 10px;
        background-color: #E0ECFF;
        font-size: 20px;
        font-weight: bold;
    }
    .inline{
        display:inline
    }
    .row_container{
        padding:8px 5px 5px 5px;
    }
    .add_label{
width:82px;
display:-moz-inline-box; /* css注释：for ff2 */ 
display:inline-block; 
    }


    .uploadify-button {
      background-color: #A0D468;
    background-image: none;
    color: #FFF;
    font-size: 14px;
    padding: 2px 15px;

    border: none;
}
.uploadify-button:hover{
color:#FFF;
background-color: #f0ad4e;
background-image: none;
}
.uploadify-queue{
    width:50%;
}
.uploadify-progress{
    width:95%;
}
.textbox textarea.textbox-text {
white-space: pre-wrap;
}

</style>
<div id="zdstool">    

<table>
<tr>

	<td>

	        <a href="#" class="easyui-linkbutton"  onclick="viewZds('index')" data-options="iconCls:'icon-standard-application-view-gallery',plain:true">查看</a> 
	 
	</td>
	<td>
    	<div class="datagrid-btn-separator"></div>
	</td>    
   	<td>
	  <a href="#" class="easyui-linkbutton"  onclick="reloadZds()" data-options="iconCls:'icon-standard-arrow-refresh',plain:true">刷新</a> 
   	</td>
	<td>
	     <div class="datagrid-btn-separator"></div>
	</td>
   <td>
     	<div style="float:right;">        
               <input  id='search_zds_box' class="easyui-searchbox" data-options="" style="width:400px;"/>
			   </div>
			  
			      
			   <div id="mm_zds" style="width:400px">
			    <div data-options="name:'content',iconCls:'icon-standard-table-edit',selected:true">全局搜索</div>

	<div data-options="name:'title',iconCls:'icon-standard-table-edit'">名称</div>
		<div data-options="name:'ids',iconCls:'icon-standard-table-edit'">编号</div>
        <div data-options="name:'nickname',iconCls:'icon-standard-table-edit'">作者</div>

</div>
	   </td>
	   	 <td>
     <div class="datagrid-btn-separator"></div>
 </td>
 	 <td>
       <a href="#" id="finaZdsBtn" class="easyui-linkbutton"  onclick="finaSearchZds()" data-options="iconCls:'icon-search',plain:true">显示高级搜索</a>
 </td>
</tr>

</table>
<!-- 全局搜索 -->

    

<table  id="finaBoxZds" style="display:none;">
<tr >
<td style="padding:0px 0px 0px 5px" colspan="5">
   <div class="table-btn-separator"></div>
</td>
</tr>
	<tr>
		<td>
			  <div class="finaSeDiv">
        <label for="name">编号:</label>
        <input class="easyui-textbox" type="text" name="ids" id="f_ids" style="width:130px" />
    </div>
		</td>
		<td>
			 <div class="finaSeDiv">
        <label for="name">名称:</label>
        <input class="easyui-textbox" type="text" name="title" id="f_title" style="width:130px" />
    </div>
		</td>
		<td>
			<div class="finaSeDiv">
        <label for="name">车间:</label>

 <input id="f_cj" name="cj" class="easyui-textbox" data-options="iconCls:'',editable:true,panelHeight:'auto'"  style="width:130px" />

     
    </div>
		</td>
		<td>
			 <div class="finaSeDiv">
        <label for="name">工位:</label>

<select id="f_gw" class="easyui-combobox" name="gws" style="width:130px;">   

</select>  
       
 <!-- <input id="f_gw" name="gws" class="easyui-textbox" data-options="iconCls:'',editable:true,panelHeight:'auto'"  style="width:130px" /> -->
    </div>
		</td>
         <td>
        <div class="finaSeDiv">
        <label for="name">车型/配置:</label>
        <input class="easyui-textbox" type="text" name="cx" id="f_cx" style="width:130px" />
    </div>
        </td>
      


        
	</tr>
	<tr>
       <td>
        <div class="finaSeDiv">
        <label for="name">分组:</label>

         <input id="ffz_edit" class="easyui-combogrid" data-options="" name="fz[]" style="width:120px;"/>

    </div>
        </td>
<td>
	<div>
        <label for="name">作者:</label>
        <input class="easyui-textbox" type="text" name="nickname" id="f_nickname" style="width:130px" />
    </div>
		</td>


	
		
		<td colspan="2">

		
			<div class="finaSeDiv2">
        <label for="name">日期:</label>

        <input  name="creatdates" id="f_creatdates"   type= "text" class= "easyui-datebox" style="width:100px"/>  到  
         <input  name="creatdatee" id="f_creatdatee"   type= "text" class= "easyui-datebox" style="width:100px"/>
  
        <a id="finSerBtn" href="#" onclick="finaZds()" class="easyui-linkbutton" data-options="iconCls:'icon-search'">搜索</a>
    </div>
		</td>
	</tr>
</table>




</div>



<script src="/solve/Public/App/zds/index.js"></script>
<script type="text/javascript">


	$('#search_zds_box').searchbox({
		searcher : function(value, name) {
			var queryParams=$("#zds_dg").datagrid('options').queryParams;
			queryParams[name]=value;
			$("#zds_dg").datagrid('options').queryParams = queryParams;
			$("#zds_dg").datagrid("load");
		},
		menu : '#mm_zds',
		prompt : '请输入搜索内容'
	});


function viewZds(back){

    var row = $('#zds_dg').datagrid("getSelected");
        if (row) {
          
                          // 获取当前tab
    var tab = $('#tab').tabs('getSelected'); 
//encodeURI() 函数可把字符串作为 URI 进行编码
    tab.panel('refresh', '/solve/index.php/Home/Zds/view?back='+back+'&id='+encodeURI(row.id));

        } else {
            $.messager.alert("请选择", "请选择要查看的作业指导书", "info");
        }
}
function reloadZds(){
	$("#zds_dg").datagrid("reload", {   
		    cx: '' 
		});
}
function finaSearchZds(){
	$("#finaBoxZds").slideToggle(function(){
	 	if($('#finaZdsBtn').linkbutton("options").text=="显示高级搜索"){
		 	$('#finaZdsBtn').linkbutton({    
	    		text: '隐藏高级搜索'   
			}); 
	 	}else{
	 		 $('#finaZdsBtn').linkbutton({    
    			text: '显示高级搜索'   
			}); 
	 	}
	});
}
 function finaZds(){
 	$('#zds_dg').datagrid('load',{
		ids:$("#f_ids").val(),
		title:$("#f_title").val(),
		cj:$('#f_cj').combobox('getValue'),
		gw:$('#f_gw').combobox('getValue'),
		fz:$('#ffz_edit').combobox('getValue'),
		cx:$("#f_cx").val(),
		nickname:$("#f_nickname").val(),
		dates:$("#f_creatdates").datebox('getValue'),
		datee:$("#f_creatdatee").datebox('getValue')
	});

}
</script>